<%@ page language="java" contentType="text/html; charset=UTF-8" pageEncoding="UTF-8" %>
<%
    String path = request.getContextPath();
    String basePath = request.getScheme() + "://" + request.getServerName() + ":" + request.getServerPort() + path + "/";
    String adminBasePath = basePath + "admin/";
%>

<script>
    var basePath = "<%=basePath%>";
    var adminBasePath = "<%=adminBasePath%>";
</script>